package cn.dwong.msgGateway.base;

/**
 * @author 73202
 * @date 2022/3/9 18:28
 */
public class LoginApiResponse extends ApiResponse{
    private String sessionId;

    public LoginApiResponse(int code, String message, String sessionId) {
        super(code, message);
        this.sessionId = sessionId;
    }

    public LoginApiResponse(String sessionId) {
        this.sessionId = sessionId;
    }

    public String getSessionId() {
        return sessionId;
    }

    public void setSessionId(String sessionId) {
        this.sessionId = sessionId;
    }

    public static ApiResponse ofLoginSuccess(String sessionId) {
        return new LoginApiResponse(Status.SUCCESS.getCode(), Status.SUCCESS.getStandardMessage(),sessionId);
    }

}
